package com.neusoft.yuejian_01.activity;

import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.neusoft.yuejian_01.R;
import com.neusoft.yuejian_01.base.BaseActivity;
import com.neusoft.yuejian_01.model.ConstPhoto;

import it.sephiroth.android.library.picasso.Picasso;

public class GiftDetailActivity extends BaseActivity {
   private TextView GiftName,GiftValue;
    private ImageView back, Gpic;

//对xml布局赋值
protected void initView() {
    setContentView(R.layout.activity_gift_detail);
        GiftName=(TextView)findViewById(R.id.Gname);
        GiftValue=(TextView)findViewById(R.id.Gvalue);
        back=(ImageView)findViewById(R.id.greturn);
        Gpic=(ImageView)findViewById(R.id.Gpic);

        Bundle bundle=this.getIntent().getExtras();
        String gname=bundle.getString("g_name");
        String gvalue=bundle.getString("g_values");
        String hpic= ConstPhoto.BASE_URL+ConstPhoto.GiftFile+bundle.getString("g_pic");
        Picasso.with(this)
                .load(hpic)
                .into(Gpic);
        GiftName.setText(gname);
        GiftValue.setText(gvalue);

    }
//返回
protected void initEvents() {
             back.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                finish();
            }
        });

    }

    @Override
    protected void initData() {

    }

}
